package com.project.bean;

import java.time.LocalDate;

/**
 * 设施实体类
 */
public class ToolBean {
    /**
     * 设施编号
     */
    private Integer toolId;
    /**
     * 设施描述
     */
    private String toolDesc;

    /**
     * 报损日期
     */
    private LocalDate toolDate = LocalDate.now();

    /**
     * 是否解决
     */
    private String toolStatus = "未解决";

    /**
     * 房间对象
     */
    private RoomBean roomBean;

    public ToolBean() {
    }

    public ToolBean(Integer toolId, String toolDesc, LocalDate toolDate, String toolStatus, RoomBean roomBean) {
        this.toolId = toolId;
        this.toolDesc = toolDesc;
        this.toolDate = toolDate;
        this.toolStatus = toolStatus;
        this.roomBean = roomBean;
    }

    public ToolBean(String toolDesc,Integer roomId) {
        this.toolDesc = toolDesc;
        this.roomBean = new RoomBean();
        this.roomBean.setRoomId(roomId);
    }

    public Integer getToolId() {
        return toolId;
    }

    public void setToolId(Integer toolId) {
        this.toolId = toolId;
    }

    public String getToolDesc() {
        return toolDesc;
    }

    public void setToolDesc(String toolDesc) {
        this.toolDesc = toolDesc;
    }

    public LocalDate getToolDate() {
        return toolDate;
    }

    public void setToolDate(LocalDate toolDate) {
        this.toolDate = toolDate;
    }

    public String getToolStatus() {
        return toolStatus;
    }

    public void setToolStatus(String toolStatus) {
        this.toolStatus = toolStatus;
    }

    public RoomBean getRoomBean() {
        return roomBean;
    }

    public void setRoomBean(RoomBean roomBean) {
        this.roomBean = roomBean;
    }

    @Override
    public String toString() {
        return "ToolBean{" +
                "toolId=" + toolId +
                ", toolDesc='" + toolDesc + '\'' +
                ", toolDate=" + toolDate +
                ", toolStatus='" + toolStatus + '\'' +
                ", roomBean=" + roomBean +
                '}'+"\n";
    }
}
